package model;

import web.model.Bean;
import web.model.UUID;

public class PerformBean extends Bean {

	private UUID album;
	private UUID artist;
	private int index;

	public PerformBean() {
		super();
	}

	public PerformBean(UUID album, UUID artist, int index) {
		super();
		this.album = album;
		this.artist = artist;
		this.index = index;
	}

	public UUID getAlbum() {
		return album;
	}
	public void setAlbum(UUID album) {
		this.album = album;
	}
	public void setAlbum(String album) {
		this.album = new UUID(album);
	}
	public UUID getArtist() {
		return artist;
	}
	public void setArtist(UUID artist) {
		this.artist = artist;
	}
	public void setArtist(String artist) {
		this.artist = new UUID(artist);
	}
	public int getIndex() {
		return index;
	}
	public void setIndex(int index) {
		this.index = index;
	}
	public void setIndex(String index) {
		this.index = Integer.valueOf(index);
	}

	@Override
	public String toString() {
		StringBuffer line = new StringBuffer();
		line.append("PerformBean [id:");
		line.append(getId());
		line.append(", album:");
		line.append(album);
		line.append(", artist:");
		line.append(artist);
		line.append(", index:");
		line.append(index);
		line.append("]");
		return line.toString();
	}
}
